# Maintainer: Felix Yan <felixonmars@gmail.com>
# Contributor: Dale Blount <dale@archlinux.org>

pkgname=perl-net-cidr-lite
_realname=Net-CIDR-Lite
pkgver=0.22
pkgrel=2
pkgdesc="Perl extension for merging IPv4 or IPv6 CIDR addresses"
arch=('any')
license=('PerlArtistic')
url="https://search.cpan.org/dist/${_realname}/"
depends=('perl>=5.10.0')
options=(!emptydirs)
source=(https://search.cpan.org/CPAN/authors/id/S/ST/STIGTSP/${_realname}-${pkgver}.tar.gz)
sha512sums=('5d89c0b6d950e5cb4c7eb9639829d76a67373865f5582f61d3e384636b176ac08335a9210d05a53c54105fecfb8ec98ae115cba3d181aed3032370d50f3aec9f')

build() {
  cd ${_realname}-${pkgver}
  # install module in vendor directories.
  PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
  make
}

package() {
  cd ${_realname}-${pkgver}
  make install DESTDIR="${pkgdir}"
}
